<!DOCTYPE html>
<!--
    Licensed to the Apache Software Foundation (ASF) under one
    or more contributor license agreements.  See the NOTICE file
    distributed with this work for additional information
    regarding copyright ownership.  The ASF licenses this file
    to you under the Apache License, Version 2.0 (the
    "License"); you may not use this file except in compliance
    with the License.  You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing,
    software distributed under the License is distributed on an
    "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
     KIND, either express or implied.  See the License for the
    specific language governing permissions and limitations
    under the License.
-->
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
        <meta name="format-detection" content="telephone=no" />
        <meta name="viewport" content="user-scalable=no, initial-scale=1, maximum-scale=1, minimum-scale=1, width=device-width, height=device-height, target-densitydpi=device-dpi" />
        <link rel="stylesheet" type="text/css" href="css/index.css" />
        <title>Barcode Scanner Demo</title>
    </head>
    <body>
        <div class="app">
            <!-- "Page" 1 - Scanning links -->
            <div id="home_page">          
                <div class="header_bar">
                    <h1>This App Needs A Name</h1>
                    <p><strong>User:</strong> Chris Brown</p>
                </div>           

                <div id="deviceready" class="link_container blink">
                    <p class="event listening">Connecting to Device...</p>
                    <p class="event received">Device is Ready to Scan</p>
                </div>
                
                <div id="scan_links" class="link_container removeTop">
                    <ul>
                        <li><a href="#" class="menu_button green" id="scan">SCAN PRODUCT</a></li>
                        <li><a href="#" class="menu_button blue" onclick="goToPage(3)">ADD NEW PRODUCT</a></li>
                    </ul>
                    <hr>
                </div>
            </div>
    
            <!-- "Page" 2 - Enter Quantity -->
            <div id="quantity_page">
                <div class="header_bar">
                    <h1>This App Needs a Name</h1>
                    <p><strong>User:</strong> Chris Brown</p>
                </div> 
                
                <div id="quantity_form" class="link_container">
                    <form id="quant_form" action="#" method="POST">
                        <ul>
                            <li>
                                <h2>Product Title</h2>
                            </li>
                            <li>
                                <label>Product Quantity</label>
                                <input type="number" name="product_quantity" id="product_quantity" >
                                <input type="hidden" name="product_barcode" id="product_barcode" >
                            </li>
                            <li>
                                <input type="button" value="SUBMIT QUANTITY" class="menu_button green" id="quantity_submit" >
                            </li>
                            <li>
                                <a href="#" class="menu_button" onclick="goToPage(1)">CANCEL SCAN</a>
                            </li>
                        </ul>
                    </form>
                    
                </div>   
            </div>
            
            <!-- "Page" 3 - Add New Product -->
            <div id="add_product_page">
                <div class="header_bar">
                    <h1>This App Needs a Name</h1>
                    <p><strong>User:</strong> Chris Brown</p>
                </div> 
                
                <div class="link_container">
                    <form id="add_product_form" action="#">
                        <ul>
                            <li>
                                <h2>Add Product</h2>
                            </li>
                            <li><a href="#" class="menu_button green" id="add_product_scan">SCAN PRODUCT</a></li>
                            <li>
                                <label>Barcode</label>
                                <input type="number" id="add_product_barcode" >
                            </li>
                            <li>
                                <label>Product Title</label>
                                <input type="text" id="product_title" >
                            </li>
                            <li>
                                <label>Product Description</label>
                                <textarea id="product_description"></textarea>
                            </li>
                            <li>
                                <label>Product Category</label>
                                <input type="text" id="product_category" value="generate from php" >
                            </li>
                            <li>
                                <label>Pack Quantity</label>
                                <input type="number" id="pack_quantity" >
                            </li>
                            <li>
                                <label>Maximum Stock Level</label>
                                <input type="number" id="max_stock" >
                            </li>
                            <li>
                                <label>Current Stock Level</label>
                                <input type="number" id="current_stock" >
                            </li>
                            <li>
                                <input type="button" value="SUBMIT PRODUCT" class="menu_button green" id="add_product_submit" >
                            </li>
                            <li>
                                <a href="#" class="menu_button" onclick="goToPage(1)">RETURN HOME</a>
                            </li>
                        </ul>
                    </form> 
                </div>
            </div>
            
            <!-- "Page" 4 - Employee Login -->
            <div id="quantity_page">
                <div class="header_bar">
                    <h1>This App Needs a Name</h1>
                    <p><strong>User:</strong> Chris Brown</p>
                </div> 
                
                <div id="quantity_form" class="link_container">
                    <form id="quant_form" action="#" method="POST">
                        <ul>
                            <li>
                                <h2>Employee Login</h2>
                            </li>
                            <li>
                                <label>Employee ID</label>
                                <input type="number" id="emp_id" >
                            </li>
                            <li>
                                <label>Password</label>
                                <input type="password" id="login_password" >
                            </li>
                            <li>
                                <input type="button" value="LOGIN" class="menu_button green" id="login_submit" >
                            </li>
                            <li>
                                <a href="#" class="menu_button" onclick="goToPage(1)">RETURN HOME</a>
                            </li>
                        </ul>
                    </form>                    
                </div>   
            </div>
            
            <!--<h2>OPENING LINKS:</h2>
            <p><a href="#" class="topcoat-button" onclick="window.open('http://www.nhl.com', '_blank', 'location=yes');">InAppBrowser</a></p>
            <p><a href="#" class="topcoat-button" onclick="window.open('http://www.nhl.com', '_system', 'location=yes');">System Browser</a></p>
            <p><a href="#" class="topcoat-button" onclick="window.open('http://www.yahoo.com', '_self', 'location=yes');">This Webview</a></p>
            <p><a href="#" class="topcoat-button" onclick="window.plugins.childBrowser.showWebPage('http://www.nhl.com', {});">ChildBrowser</a></p>
        -->
        </div>
        <script type="text/javascript" src="cordova.js"></script>
        <script type="text/javascript" src="barcodescanner.js"></script>
        <script type="text/javascript" src="childbrowser.js"></script>
        <script type="text/javascript" src="js/index.js"></script>
        <script type="text/javascript" src="js/jquery.min.js"></script>
        <script type="text/javascript" src="js/jquery_scripts.js"></script>
        <script type="text/javascript">
            app.initialize();
        </script>
    </body>
</html>
